package com.th.supcom.pds.impl.manager.impl;

import java.util.List;
import java.util.Map;

import net.carefx.fc.framework.db.manager.GetSequenceHelper;

import org.apache.ibatis.session.RowBounds;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.th.supcom.pds.domain.pojo.PhamWindowConfig;
import com.th.supcom.pds.impl.dao.PhamWindowConfigMapper;
import com.th.supcom.pds.impl.manager.PhamWindowConfigManager;

/**
 * PhamWindowConfig 管理接口实现.
 * 
 * 药房窗口属性列表.
 */
public class PhamWindowConfigManagerImpl implements PhamWindowConfigManager
{
    public static final String TAB_PHAM_WINDOW_CONFIG = "PHAM_WINDOW_CONFIG";

    private PhamWindowConfigMapper m_phamWindowConfigMapper;

    /** 序列生成器. */
    private GetSequenceHelper m_getSequenceHelper;

    /**
     * 默认的构造函数.
     */
    public PhamWindowConfigManagerImpl ()
    {

    }

    /**
     * 获取PhamWindowConfigMapper.
     * 
     * @return PhamWindowConfigMapper.
     */
    public PhamWindowConfigMapper getPhamWindowConfigMapper ()
    {
        return m_phamWindowConfigMapper;
    }

    /**
     * 注入PhamWindowConfigMapper.
     * 
     * @param phamWindowConfigMapper set phamWindowConfigMapper.
     */
    public void setPhamWindowConfigMapper (PhamWindowConfigMapper phamWindowConfigMapper)
    {
        m_phamWindowConfigMapper = phamWindowConfigMapper;
    }

    /**
     * 获取序列.
     * 
     * @return GetSequenceHelper
     */
    public GetSequenceHelper getGetSequenceHelper ()
    {
        return m_getSequenceHelper;
    }

    /**
     * 注入序列.
     * 
     * @param getSequenceHelper getSequenceHelper.
     */
    public void setGetSequenceHelper (GetSequenceHelper getSequenceHelper)
    {
        m_getSequenceHelper = getSequenceHelper;
    }

    @Override
    public PhamWindowConfig getPhamWindowConfigByID (Long id)
    {
        return m_phamWindowConfigMapper.getPhamWindowConfigByID (id);
    }

    @Override
    public Long getPhamWindowConfigSeq ()
    {
        return m_getSequenceHelper.getNextSequenceId (TAB_PHAM_WINDOW_CONFIG);
    }

    @Override
    public List <PhamWindowConfig> findPhamWindowConfigListByExample (PhamWindowConfig phamWindowConfig)
    {
        return m_phamWindowConfigMapper.findPhamWindowConfigListByExample (phamWindowConfig);
    }

    @Override
    public int findPhamWindowConfigCountByExample (PhamWindowConfig phamWindowConfig)
    {
        return m_phamWindowConfigMapper.findPhamWindowConfigCountByExample (phamWindowConfig);
    }

    @Override
    public List <PhamWindowConfig> findPhamWindowConfigListByMap (Map <String, Object> params)
    {
        return m_phamWindowConfigMapper.findPhamWindowConfigListByMap (params);
    }

    @Override
    public List <PhamWindowConfig> findPhamWindowConfigPagingByMap (Map <String, Object> params, Integer offset, Integer limit)
    {
        return m_phamWindowConfigMapper.findPhamWindowConfigPagingByMap (new RowBounds (offset, limit), params);
    }

    @Override
    public Integer findPhamWindowConfigCountByMap (Map <String, Object> params)
    {
        return m_phamWindowConfigMapper.findPhamWindowConfigCountByMap (params);
    }

    @Override
    public int modifyPhamWindowConfig (PhamWindowConfig phamWindowConfig)
    {
        return m_phamWindowConfigMapper.modifyPhamWindowConfig (phamWindowConfig);
    }

    @Override
    public int modifyPhamWindowConfigByExample (PhamWindowConfig phamWindowConfig)
    {
        return m_phamWindowConfigMapper.modifyPhamWindowConfigByExample (phamWindowConfig);
    }

    @Override
    public int removePhamWindowConfigByID (Long id)
    {
        return m_phamWindowConfigMapper.removePhamWindowConfigByID (id);
    }

    @Override
    public int removePhamWindowConfigByMap (Map <String, Object> params)
    {
        return m_phamWindowConfigMapper.removePhamWindowConfigByMap (params);
    }

    @Override
    public void addPhamWindowConfig (PhamWindowConfig phamWindowConfig)
    {
        phamWindowConfig.setPhamWindowConfigId (getPhamWindowConfigSeq ());
        m_phamWindowConfigMapper.addPhamWindowConfig (phamWindowConfig);
    }

    /** 日志记录器. */
    public static final Logger s_logger = LoggerFactory.getLogger (PhamWindowConfigManagerImpl.class);

    /** 公司版权信息. */
    public static final String copyright = "Copyright 2014, TH Supcom Corporation";

    /** 提交路径. */
    public static final String SCC_BRANCH = "$URL$";

    /** 提交日期. */
    public static final String SCC_LAST_MODIFICATION_DATE = "$Date$";

    /** 最终修改人员. */
    public static final String SCC_LAST_MODIFIER_NAME = "$Author$";

    /** 最终版本号. */
    public static final String SCC_REVISION = "$Revision$";
}